<html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Hammerspoon docs: Pastebin</title>
    <style type="text/css">
      a { text-decoration: none; }
      a:hover { text-decoration: underline; }
      th { background-color: #DDDDDD; vertical-align: top; padding: 3px; }
      td { width: 100%; background-color: #EEEEEE; vertical-align: top; padding: 3px; }
      table { width: 100% ; border: 1px solid #0; text-align: left; }
      section > table table td { width: 0; }
    </style>
    <link rel="stylesheet" href="docs.css" type="text/css" media="screen" />
  </head>
  <body>
    <header>
      <h1><a href="./index.html">docs</a> &raquo; Pastebin</h1>
      <p>Send clipboard contents to Pastebin</p>
<p>Conversion of tldm's pastebin gist to a Spoon https://gist.github.com/tdlm/5eba0299f2924a8aaf46
Code by @tdlm, spoon by Tyler Thrailkill <a href="mailto:tyler.b.thrailkill@gmail.com">tyler.b.thrailkill@gmail.com</a></p>
<p>https://github.com/snowe2010</p>

      </header>
      <h3>API Overview</h3>
      <ul>
        <li>Variables - Configurable values</li>
          <ul>
            <li><a href="#api_dev_key">api_dev_key</a></li>
            <li><a href="#api_user_key">api_user_key</a></li>
            <li><a href="#expire">expire</a></li>
            <li><a href="#format">format</a></li>
            <li><a href="#logger">logger</a></li>
            <li><a href="#private">private</a></li>
          </ul>
        <li>Methods - API calls which can only be made on an object returned by a constructor</li>
          <ul>
            <li><a href="#bindHotkeys">bindHotkeys</a></li>
            <li><a href="#paste">paste</a></li>
          </ul>
      </ul>
      <h3>API Documentation</h3>
        <h4 class="documentation-section">Variables</h4>
          <section id="api_dev_key">
            <a name="//apple_ref/cpp/Variable/api_dev_key" class="dashAnchor"></a>
            <h5><a href="#api_dev_key">api_dev_key</a></h5>
            <table>
              <tr>
                <th>Signature</th>
                <td><code>Pastebin.api_dev_key</code></td>
              </tr>
              <tr>
                <th>Type</th>
                <td>Variable</td>
              </tr>
              <tr>
                <th>Description</th>
                <td><p>String api developer key. Can be found <a href="http://pastebin.com/api">here</a></p>
</td>
              </tr>
              <tr>
                <th>Source</th>
                <td><a href="https://github.com/Hammerspoon/Spoons/blob/master/Source/Pastebin.spoon/init.lua#L19">Source/Pastebin.spoon/init.lua line 19</a></td>
              </tr>
            </table>
          </section>
          <section id="api_user_key">
            <a name="//apple_ref/cpp/Variable/api_user_key" class="dashAnchor"></a>
            <h5><a href="#api_user_key">api_user_key</a></h5>
            <table>
              <tr>
                <th>Signature</th>
                <td><code>Pastebin.api_user_key</code></td>
              </tr>
              <tr>
                <th>Type</th>
                <td>Variable</td>
              </tr>
              <tr>
                <th>Description</th>
                <td><p>String api user key. Can be generated <a href="http://pastebin.com/api/api_user_key.html">here</a></p>
</td>
              </tr>
              <tr>
                <th>Source</th>
                <td><a href="https://github.com/Hammerspoon/Spoons/blob/master/Source/Pastebin.spoon/init.lua#L24">Source/Pastebin.spoon/init.lua line 24</a></td>
              </tr>
            </table>
          </section>
          <section id="expire">
            <a name="//apple_ref/cpp/Variable/expire" class="dashAnchor"></a>
            <h5><a href="#expire">expire</a></h5>
            <table>
              <tr>
                <th>Signature</th>
                <td><code>Pastebin.expire</code></td>
              </tr>
              <tr>
                <th>Type</th>
                <td>Variable</td>
              </tr>
              <tr>
                <th>Description</th>
                <td><p>String indicating how long until the paste expires. Default is 'N' (Never)</p>
</td>
              </tr>
              <tr>
                  <th>Notes</th>
                  <td><ul>
<li>Valid expiration times at this time are (current list can be found <a href="https://pastebin.com/api#6">here</a>)</li>
<li>N</li>
<li>10M</li>
<li>1H</li>
<li>1D</li>
<li>1W</li>
<li>2W</li>
<li>1M</li>
<li>6M</li>
<li>1Y</li>
</ul>
</td>
              </tr>
              <tr>
                <th>Source</th>
                <td><a href="https://github.com/Hammerspoon/Spoons/blob/master/Source/Pastebin.spoon/init.lua#L34">Source/Pastebin.spoon/init.lua line 34</a></td>
              </tr>
            </table>
          </section>
          <section id="format">
            <a name="//apple_ref/cpp/Variable/format" class="dashAnchor"></a>
            <h5><a href="#format">format</a></h5>
            <table>
              <tr>
                <th>Signature</th>
                <td><code>Pastebin.format</code></td>
              </tr>
              <tr>
                <th>Type</th>
                <td>Variable</td>
              </tr>
              <tr>
                <th>Description</th>
                <td><p>String indicating the format of the paste. Default is 'text' (plain text).</p>
</td>
              </tr>
              <tr>
                  <th>Notes</th>
                  <td><ul>
<li>Valid formats at this time are (current list can be found <a href="https://pastebin.com/api#5">here</a>):</li>
<li>'4cs'</li>
<li>'6502acme'</li>
<li>'6502kickass'</li>
<li>'6502tasm'</li>
<li>'abap'</li>
<li>'actionscript'</li>
<li>'actionscript3'</li>
<li>'ada'</li>
<li>'aimms'</li>
<li>'algol68'</li>
<li>'apache'</li>
<li>'applescript'</li>
<li>'apt_sources'</li>
<li>'arm'</li>
<li>'asm'</li>
<li>'asp'</li>
<li>'asymptote'</li>
<li>'autoconf'</li>
<li>'autohotkey'</li>
<li>'autoit'</li>
<li>'avisynth'</li>
<li>'awk'</li>
<li>'bascomavr'</li>
<li>'bash'</li>
<li>'basic4gl'</li>
<li>'dos'</li>
<li>'bibtex'</li>
<li>'blitzbasic'</li>
<li>'b3d'</li>
<li>'bmx'</li>
<li>'bnf'</li>
<li>'boo'</li>
<li>'bf'</li>
<li>'c'</li>
<li>'c_winapi'</li>
<li>'c_mac'</li>
<li>'cil'</li>
<li>'csharp'</li>
<li>'cpp'</li>
<li>'cpp-winapi'</li>
<li>'cpp-qt'</li>
<li>'c_loadrunner'</li>
<li>'caddcl'</li>
<li>'cadlisp'</li>
<li>'ceylon'</li>
<li>'cfdg'</li>
<li>'chaiscript'</li>
<li>'chapel'</li>
<li>'clojure'</li>
<li>'klonec'</li>
<li>'klonecpp'</li>
<li>'cmake'</li>
<li>'cobol'</li>
<li>'coffeescript'</li>
<li>'cfm'</li>
<li>'css'</li>
<li>'cuesheet'</li>
<li>'d'</li>
<li>'dart'</li>
<li>'dcl'</li>
<li>'dcpu16'</li>
<li>'dcs'</li>
<li>'delphi'</li>
<li>'oxygene'</li>
<li>'diff'</li>
<li>'div'</li>
<li>'dot'</li>
<li>'e'</li>
<li>'ezt'</li>
<li>'ecmascript'</li>
<li>'eiffel'</li>
<li>'email'</li>
<li>'epc'</li>
<li>'erlang'</li>
<li>'euphoria'</li>
<li>'fsharp'</li>
<li>'falcon'</li>
<li>'filemaker'</li>
<li>'fo'</li>
<li>'f1'</li>
<li>'fortran'</li>
<li>'freebasic'</li>
<li>'freeswitch'</li>
<li>'gambas'</li>
<li>'gml'</li>
<li>'gdb'</li>
<li>'genero'</li>
<li>'genie'</li>
<li>'gettext'</li>
<li>'go'</li>
<li>'groovy'</li>
<li>'gwbasic'</li>
<li>'haskell'</li>
<li>'haxe'</li>
<li>'hicest'</li>
<li>'hq9plus'</li>
<li>'html4strict'</li>
<li>'html5'</li>
<li>'icon'</li>
<li>'idl'</li>
<li>'ini'</li>
<li>'inno'</li>
<li>'intercal'</li>
<li>'io'</li>
<li>'ispfpanel'</li>
<li>'j'</li>
<li>'java'</li>
<li>'java5'</li>
<li>'javascript'</li>
<li>'jcl'</li>
<li>'jquery'</li>
<li>'json'</li>
<li>'julia'</li>
<li>'kixtart'</li>
<li>'kotlin'</li>
<li>'latex'</li>
<li>'ldif'</li>
<li>'lb'</li>
<li>'lsl2'</li>
<li>'lisp'</li>
<li>'llvm'</li>
<li>'locobasic'</li>
<li>'logtalk'</li>
<li>'lolcode'</li>
<li>'lotusformulas'</li>
<li>'lotusscript'</li>
<li>'lscript'</li>
<li>'lua'</li>
<li>'m68k'</li>
<li>'magiksf'</li>
<li>'make'</li>
<li>'mapbasic'</li>
<li>'markdown'</li>
<li>'matlab'</li>
<li>'mirc'</li>
<li>'mmix'</li>
<li>'modula2'</li>
<li>'modula3'</li>
<li>'68000devpac'</li>
<li>'mpasm'</li>
<li>'mxml'</li>
<li>'mysql'</li>
<li>'nagios'</li>
<li>'netrexx'</li>
<li>'newlisp'</li>
<li>'nginx'</li>
<li>'nim'</li>
<li>'text'</li>
<li>'nsis'</li>
<li>'oberon2'</li>
<li>'objeck'</li>
<li>'objc'</li>
<li>'ocaml-brief'</li>
<li>'ocaml'</li>
<li>'octave'</li>
<li>'oorexx'</li>
<li>'pf'</li>
<li>'glsl'</li>
<li>'oobas'</li>
<li>'oracle11'</li>
<li>'oracle8'</li>
<li>'oz'</li>
<li>'parasail'</li>
<li>'parigp'</li>
<li>'pascal'</li>
<li>'pawn'</li>
<li>'pcre'</li>
<li>'per'</li>
<li>'perl'</li>
<li>'perl6'</li>
<li>'php'</li>
<li>'php-brief'</li>
<li>'pic16'</li>
<li>'pike'</li>
<li>'pixelbender'</li>
<li>'pli'</li>
<li>'plsql'</li>
<li>'postgresql'</li>
<li>'postscript'</li>
<li>'povray'</li>
<li>'powerbuilder'</li>
<li>'powershell'</li>
<li>'proftpd'</li>
<li>'progress'</li>
<li>'prolog'</li>
<li>'properties'</li>
<li>'providex'</li>
<li>'puppet'</li>
<li>'purebasic'</li>
<li>'pycon'</li>
<li>'python'</li>
<li>'pys60'</li>
<li>'q'</li>
<li>'qbasic'</li>
<li>'qml'</li>
<li>'rsplus'</li>
<li>'racket'</li>
<li>'rails'</li>
<li>'rbs'</li>
<li>'rebol'</li>
<li>'reg'</li>
<li>'rexx'</li>
<li>'robots'</li>
<li>'rpmspec'</li>
<li>'ruby'</li>
<li>'gnuplot'</li>
<li>'rust'</li>
<li>'sas'</li>
<li>'scala'</li>
<li>'scheme'</li>
<li>'scilab'</li>
<li>'scl'</li>
<li>'sdlbasic'</li>
<li>'smalltalk'</li>
<li>'smarty'</li>
<li>'spark'</li>
<li>'sparql'</li>
<li>'sqf'</li>
<li>'sql'</li>
<li>'standardml'</li>
<li>'stonescript'</li>
<li>'sclang'</li>
<li>'swift'</li>
<li>'systemverilog'</li>
<li>'tsql'</li>
<li>'tcl'</li>
<li>'teraterm'</li>
<li>'thinbasic'</li>
<li>'typoscript'</li>
<li>'unicon'</li>
<li>'uscript'</li>
<li>'upc'</li>
<li>'urbi'</li>
<li>'vala'</li>
<li>'vbnet'</li>
<li>'vbscript'</li>
<li>'vedit'</li>
<li>'verilog'</li>
<li>'vhdl'</li>
<li>'vim'</li>
<li>'visualprolog'</li>
<li>'vb'</li>
<li>'visualfoxpro'</li>
<li>'whitespace'</li>
<li>'whois'</li>
<li>'winbatch'</li>
<li>'xbasic'</li>
<li>'xml'</li>
<li>'xorg_conf'</li>
<li>'xpp'</li>
<li>'yaml'</li>
<li>'z80'</li>
<li>'zxbasic'</li>
</ul>
</td>
              </tr>
              <tr>
                <th>Source</th>
                <td><a href="https://github.com/Hammerspoon/Spoons/blob/master/Source/Pastebin.spoon/init.lua#L52">Source/Pastebin.spoon/init.lua line 52</a></td>
              </tr>
            </table>
          </section>
          <section id="logger">
            <a name="//apple_ref/cpp/Variable/logger" class="dashAnchor"></a>
            <h5><a href="#logger">logger</a></h5>
            <table>
              <tr>
                <th>Signature</th>
                <td><code>Pastebin.logger</code></td>
              </tr>
              <tr>
                <th>Type</th>
                <td>Variable</td>
              </tr>
              <tr>
                <th>Description</th>
                <td><p>Logger object used within the Spoon. Can be accessed to set the default log level for the messages coming from the Spoon.</p>
</td>
              </tr>
              <tr>
                <th>Source</th>
                <td><a href="https://github.com/Hammerspoon/Spoons/blob/master/Source/Pastebin.spoon/init.lua#L313">Source/Pastebin.spoon/init.lua line 313</a></td>
              </tr>
            </table>
          </section>
          <section id="private">
            <a name="//apple_ref/cpp/Variable/private" class="dashAnchor"></a>
            <h5><a href="#private">private</a></h5>
            <table>
              <tr>
                <th>Signature</th>
                <td><code>Pastebin.private</code></td>
              </tr>
              <tr>
                <th>Type</th>
                <td>Variable</td>
              </tr>
              <tr>
                <th>Description</th>
                <td><p>Integer indicating whether a paste should be public, unlisted, or private. Default is 0 (public). (0=public, 1=unlisted, 2=private)</p>
</td>
              </tr>
              <tr>
                <th>Source</th>
                <td><a href="https://github.com/Hammerspoon/Spoons/blob/master/Source/Pastebin.spoon/init.lua#L29">Source/Pastebin.spoon/init.lua line 29</a></td>
              </tr>
            </table>
          </section>
        <h4 class="documentation-section">Methods</h4>
          <section id="bindHotkeys">
            <a name="//apple_ref/cpp/Method/bindHotkeys" class="dashAnchor"></a>
            <h5><a href="#bindHotkeys">bindHotkeys</a></h5>
            <table>
              <tr>
                <th>Signature</th>
                <td><code>Pastebin:bindHotkeys(mapping)</code></td>
              </tr>
              <tr>
                <th>Type</th>
                <td>Method</td>
              </tr>
              <tr>
                <th>Description</th>
                <td><p>Binds hotkeys for Pastebin</p>
</td>
              </tr>
              <tr>
                  <th>Parameters</th>
                  <td><ul>
<li>mapping - A table containing hotkey objifier/key details for the following items:<ul>
<li>paste - paste to Pastebin</li>
</ul>
</li>
</ul>
</td>
              </tr>
              <tr>
                  <th>Returns</th>
                  <td></td>
              </tr>
              <tr>
                <th>Source</th>
                <td><a href="https://github.com/Hammerspoon/Spoons/blob/master/Source/Pastebin.spoon/init.lua#L368">Source/Pastebin.spoon/init.lua line 368</a></td>
              </tr>
            </table>
          </section>
          <section id="paste">
            <a name="//apple_ref/cpp/Method/paste" class="dashAnchor"></a>
            <h5><a href="#paste">paste</a></h5>
            <table>
              <tr>
                <th>Signature</th>
                <td><code>Pastebin:paste(private, expire, format)</code></td>
              </tr>
              <tr>
                <th>Type</th>
                <td>Method</td>
              </tr>
              <tr>
                <th>Description</th>
                <td><p>Pastes an item to Pastebin using the Pastebin api</p>
</td>
              </tr>
              <tr>
                  <th>Parameters</th>
                  <td><ul>
<li>private - Integer specifying whether the paste should be public, private, or unlisted. Defaults to obj.private (0=public)</li>
<li>expire - String specifying the TTL for the paste. Defaults to obj.expire ('N'=never). Valid values are listed on obj.expire</li>
<li>format - String specifying the appropriate Pastebin format enum. Default is obj.format ('text'). Valid values are listed on obj.format</li>
</ul>
</td>
              </tr>
              <tr>
                  <th>Returns</th>
                  <td></td>
              </tr>
              <tr>
                <th>Source</th>
                <td><a href="https://github.com/Hammerspoon/Spoons/blob/master/Source/Pastebin.spoon/init.lua#L318">Source/Pastebin.spoon/init.lua line 318</a></td>
              </tr>
            </table>
          </section>
  </body>
</html>